import axios from '../utils/axios'
import api from '../api/index'

const getAllCall = () => {
    return new Promise((reslove, reject) => {
        axios.get(api.callApi.Call_getAll)
            .then(res => {
                reslove(res.data)
            })
            .catch(err => reject(err))
    })
}
const addCall = (data) => {
    return new Promise((resolve, reject) => {
        axios.post(api.callApi.call_add, data)
            .then(res => {
                resolve(res.data)
            })
            .catch(err => reject(err))
    })
}


export default {
    getAllCall,
    addCall,
}